//
//  KLSGSpeackView.m
//  KaoLaShiGuangFM
//
//  Created by lanou3g on 15/11/1.
//  Copyright © 2015年 com.lanou3g. All rights reserved.
//

#import "KLSGSpeackView.h"

@interface KLSGSpeackView ()

@property (nonatomic, assign) CGFloat width;
@property (nonatomic, assign) CGFloat height;

@end

@implementation KLSGSpeackView

- (instancetype)initWithFrame:(CGRect)frame
{
    self = [super initWithFrame:frame];
    if (self) {
        [self addSubviews];
    }
    return self;
}

- (void)addSubviews
{
    self.figureLable = [[UILabel alloc] initWithFrame:CGRectMake(0, 0, self.frame.size.width / 6, self.frame.size.height)];
    self.figureLable.textAlignment = NSTextAlignmentCenter;
    self.figureLable.text = @"1";
//    self.figureLable.backgroundColor = [UIColor greenColor];
    self.figureLable.font = [UIFont systemFontOfSize:22];
    [self addSubview:self.figureLable];
    
    self.coverImage = [[UIImageView alloc] initWithFrame:CGRectMake(CGRectGetMaxX(self.figureLable.frame), 0, self.frame.size.width / 4, self.frame.size.height)];
    self.coverImage.backgroundColor = [UIColor yellowColor];
    [self addSubview:self.coverImage];
    
    self.titleLable = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetMaxX(self.coverImage.frame) + 10, 5, kScreenWidth / 2, 40)];
    self.titleLable.text = @"dfgfharbg";
    self.titleLable.font = [UIFont systemFontOfSize:18];
    [self addSubview:self.titleLable];
    
    self.tagsLable = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetMaxX(self.coverImage.frame) + 10, CGRectGetMaxY(self.titleLable.frame) - 10, kScreenWidth / 2, 30)];
    self.tagsLable.text = @"awegergheh5";
    self.tagsLable.font = [UIFont fontWithName:@"TimesNewRomanPSMT" size:15];
    self.tagsLable.alpha = kAlpha;
    [self addSubview:self.tagsLable];
    
    self.iconImage = [[UIImageView alloc] initWithFrame:CGRectMake(CGRectGetMaxX(self.coverImage.frame) + 10, CGRectGetMaxY(self.tagsLable.frame) - 5, 15, 15)];
    self.iconImage.image = [UIImage imageNamed:@""];
    [self addSubview:self.iconImage];
    
    self.tracksCountLable = [[UILabel alloc] initWithFrame:CGRectMake(CGRectGetMaxX(self.iconImage.frame) + 3, CGRectGetMaxY(self.tagsLable.frame) - 10, 100, 30)];
    self.tracksCountLable.text = @"1rtrqr";
    self.tracksCountLable.alpha = kAlpha;
    self.tracksCountLable.font = [UIFont fontWithName:@"TimesNewRomanPSMT" size:15];
    [self addSubview:self.tracksCountLable];
    
//    UIView *lineView = [[UIView alloc] initWithFrame:CGRectMake(CGRectGetMaxX(self.coverImage.frame) + 10, 79, kScreenWidth - 110, 1)];
//    lineView.backgroundColor = [UIColor lightGrayColor];
//    [self addSubview:lineView];
}



@end
